/// <reference path="../Scripts/jquery-1.7.1.min.js" />
/// <reference path="../Scripts/knockout-2.1.0.js" />

jQuery(document).ready(function () {
    var MyTenantViewModel = new TenantViewModel();
    ko.applyBindings(MyTenantViewModel, document.getElementById('addTenantNode'));
	ko.applyBindings(MyTenantViewModel, document.getElementById('modifyTenantNode'));
	ko.applyBindings(MyTenantViewModel, document.getElementById('listTenantNode'));
    jQuery("#newTenantForm").validate();
    jQuery('input:submit').click(function () {
        if (jQuery("#newTenantForm").valid())
        {
            MyTenantViewModel.AddTenant();

        }
        return false;
    });

    

    
});